﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NGinnBPM.MessageBus;

namespace NGinnBPM.Lib.Interfaces
{
    /// <summary>
    /// NGinn host interface
    /// </summary>
    public interface INGinnHost
    {
        /// <summary>
        /// Return NGinn Environment instance
        /// </summary>
        INGEnvironment Environment { get; }
        /// <summary>
        /// Return process package repository
        /// </summary>
        IProcessPackageRepository PackageRepository { get; }
        /// <summary>
        /// Return NGinn scheduling engine
        /// </summary>
        INGEngine NGEngine { get; }
        /// <summary>
        /// NGinn message bus
        /// </summary>
        IMessageBus MessageBus { get; }
        /// <summary>
        /// Get service locator for the underlying
        /// IOC container
        /// </summary>
        IServiceResolver ServiceLocator { get; }
        /// <summary>
        /// Start NGinn message bus and NGinn scheduling engine
        /// </summary>
        void Start();
        /// <summary>
        /// Stop background processing
        /// </summary>
        void Stop();
    }
}
